<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateConfigTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('config', function (Blueprint $table) {
            $table->increments('id');
            $table->string("type",20)->default('')->comment("类型");
            $table->string("config_key",20)->default('')->comment("配置key");
            $table->string("config_value",150)->default('')->comment("配置value");
            $table->string("app_name",20)->default('')->comment("APP名称");
            $table->tinyInteger("is_deleted")->default(0)->comment("是否删除");
            $table->smallInteger("sort")->default(50)->comment("排序 从小到大");
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('config');
    }
}
